package br.ufrgs.inf.engsoft.stp.user;

import java.util.List;

import br.ufrgs.inf.engsoft.stp.persistence.AbstractDao;

public class UserDao extends AbstractDao<User, String> {
	
	public void create(User user) {
		super.create(user);
	}
	
	public List<User> readAll() {
		return super.readAll(User.class);
	}

	public User read(String cpf) {
		return (User) super.read(User.class, cpf);
	}

	public void update(User transientObject) {
		super.update(transientObject);
	}

	public void delete(User persistentObject) {
		super.delete(persistentObject);
	}
	
	public boolean exists(String cpf) {
		return (boolean) (super.read(User.class, cpf) != null);
	}
}
